cmake_minimum_required(VERSION 3.18)
project(publish)

include_directories(
  ${PROJECT_SOURCE_DIR}
)

if(NOT TARGET flatbuffers)
  find_package(flatbuffers CONFIG REQUIRED)
endif()

if(NOT TARGET cppzmq)
  find_package(cppzmq CONFIG REQUIRED)
endif()

aux_source_directory(${PROJECT_SOURCE_DIR}/src SOURCE_FILE)

add_executable(publish ${SOURCE_FILE})

target_link_libraries( 
  publish
  PUBLIC
  cppzmq 
  cppzmq-static
  flatbuffers::flatbuffers
)